home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Safarir 3
/
SafTV-CD3.iso
/
pc
/
Bonus
/
Dessins Animés
/
static
/
jeux
/
napman.swf
/
scripts
/
frame_329
/
DoAction.as
Wrap
Text File
|
2001-11-21
|
2KB
|
104 lines
if(mangiato3 == "0")
{
px4 = int(f3x / "4");
py4 = int(f3y / "4");
restox = f3x - px4 * "4";
restoy = f3y - py4 * "4";
if(restox == "0" and restoy == "0")
{
x = f3x;
y = f3y;
call("evaluate");
xv = f3vx;
yv = f3vy;
call("controlla");
if(ok == "1")
{
f3vx = xvs;
f3vy = yvs;
call("ruotafan");
}
}
setProperty("/f3", _X, f3x * "4" + "8");
setProperty("/f3", _Y, f3y * "4" + "8");
if(f3vx == "1")
{
pros = "3";
}
else
{
pros = "0";
}
if(f3vy == "1")
{
prosy = "3";
}
else
{
prosy = "0";
}
tpx = f3x + f3vx + pros;
tpy = f3y + f3vy + prosy;
cosa = eval("r" add int(tpy / "4")).substr(int(tpx / "4") + "1","1");
if(cosa ne "X" and cosa ne "T" and cosa ne "R")
{
f3x += f3vx;
f3y += f3vy;
}
else
{
x = f3x;
y = f3y;
call("evaluate");
f3vx = xvs;
f3vy = yvs;
call("ruotafan");
}
if((px - f3x) * (px - f3x) < "10" and (py - f3y) * (py - f3y) < "10")
{
if(status == "1")
{
score += "100";
mangiato3 = "1";
tellTarget("/f3")
{
gotoAndStop(9);
}
tellTarget("/suoni")
{
gotoAndStop("magna");
play();
}
}
else
{
gameover = "1";
}
}
}
else
{
if(f3y < "56")
{
f3y += "1";
}
if("56" < f3y)
{
f3y -= "1";
}
if("56" < f3x)
{
f3x -= "1";
}
if(f3x < "56")
{
f3x += "1";
}
setProperty("/f3", _X, f3x * "4" + "8");
setProperty("/f3", _Y, f3y * "4" + "8");
if(f3y == "56" and f3x == "56")
{
mangiato3 = "0";
}
}